<template>
  <div class="login">
    <div class="box">
      <h1 align="center" style="margin-top: 20px; margin-bottom: 50px">
        <strong>积云舆情监控后台管理系统</strong>
      </h1>
      <p style="margin-top: 30px; margin-left: 100px">
        <strong>用户名 : </strong
        ><a-input
          style="width: 300px"
          v-model:value="username"
          placeholder="请输入用户名"
        />
      </p>
      <p style="margin-top: 30px; margin-left: 100px">
        <strong>密&emsp;码 : </strong
        ><a-input-password
          style="width: 300px"
          v-model:value="password"
          placeholder="请输入密码"
        />
      </p>
      <p style="margin-top: 30px; margin-left: 100px">
        <strong>验证码 : </strong
        ><a-input
          style="width: 150px"
          v-model:value="verify"
          placeholder="请输入验证码"
        />
      </p>
      <a-button type="primary" style="margin-top: 30px; margin-left: 180px">登录</a-button>
    </div>
  </div>
</template>

<script lang='ts'>
import { defineComponent, ref, reactive, toRefs, computed } from "vue";
import userApi from "../../api/user"
export default defineComponent({
  setup() {
    let state = reactive({
      username: "",
      password: "",
      verify : "",
      svgKey : "",
    });
    
    
    userApi.getCaptcha().then((res:any)=>{
        console.log(res);
    })
    return {
      ...toRefs(state),
    };
  },
});
</script>

<style scoped >
.login {
  width: 100%;
  height: 100%;
  background-color: steelblue;
  display: flex;
  align-items: center;
  justify-content: center;
}
.box {
  width: 800px;
  height: 400px;
  background-image: url("../../assets/loginbg.jpg");
  background-size: 100% 100%;
}
</style>
